package com.arvato.right.bean.bean_vo;

import java.util.Date;
import java.util.List;

import com.arvato.common.util.DateFormatUtil;
import com.arvato.minipro.bean.bean_dto.common.TreeBean;
/**
 * 权限管理之user表
 * @author ZHAN655
 *
 */
public class WxworkRightUserVo {
	/**
	 * 主键ID
	 */
    private String userId;
    /**
     * 账号
     */
    private String account;
    /**
     * 密码
     */
    private String password;
    /**
     * 昵称
     */
    private String nickname;
    /**
     * 电话
     */
    private String tel;
    /**
     * 备注
     */
    private String note;
    /**
     * 创建时间
     */
    private Date createDate;
    /**
     * 最后操作时间
     */
    private Date lastoperDate;
    /**
     * 最后操作人员
     */
    private String lastoperUser;
    /**
     * 最后操作类型
     */
    private Integer lastoperType;
    /**
     * 状态
     */
    private Integer status;
    /**
     * 该用户所持有的资源集合
     */
    private List<WxworkRightResourceVo> resourceList;
    /**
     * 该用户所持有角色的集合
     */
    private List<WxworkRightRoleVo> roleList;
    /**
     * 该用户所持有角色的集合拼接成的字符串
     */
    private String roleStr;
    /**
     * 左侧菜单树所需要的树list
     */
    private List<TreeBean> menuList;
    
    public String getUserId() {
        return userId;
    }

    public void setUserId(String userId) {
        this.userId = userId == null ? null : userId.trim();
    }

    public String getAccount() {
        return account;
    }

    public void setAccount(String account) {
        this.account = account == null ? null : account.trim();
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password == null ? null : password.trim();
    }

    public String getNickname() {
        return nickname;
    }

    public void setNickname(String nickname) {
        this.nickname = nickname == null ? null : nickname.trim();
    }

    public String getTel() {
        return tel;
    }

    public void setTel(String tel) {
        this.tel = tel == null ? null : tel.trim();
    }

    public String getNote() {
        return note;
    }

    public void setNote(String note) {
        this.note = note == null ? null : note.trim();
    }

    public String getCreateDate() {
        return DateFormatUtil.date2Str(createDate);
    }

    public void setCreateDate(Date createDate) {
        this.createDate = createDate;
    }

    public Date getLastoperDate() {
        return lastoperDate;
    }

    public void setLastoperDate(Date lastoperDate) {
        this.lastoperDate = lastoperDate;
    }

    public String getLastoperUser() {
        return lastoperUser;
    }

    public void setLastoperUser(String lastoperUser) {
        this.lastoperUser = lastoperUser == null ? null : lastoperUser.trim();
    }

    public Integer getLastoperType() {
        return lastoperType;
    }

    public void setLastoperType(Integer lastoperType) {
        this.lastoperType = lastoperType;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

	public List<WxworkRightResourceVo> getResourceList() {
		return resourceList;
	}

	public void setResourceList(List<WxworkRightResourceVo> resourceList) {
		this.resourceList = resourceList;
	}

	public List<WxworkRightRoleVo> getRoleList() {
		return roleList;
	}

	public void setRoleList(List<WxworkRightRoleVo> roleList) {
		this.roleList = roleList;
	}

	public String getRoleStr() {
		if(roleList == null || roleList.size() == 0) {
			return "";
		}
		roleStr = "";
		for(WxworkRightRoleVo resourceVo : roleList) {
			roleStr += resourceVo.getRoleName() + ";";
		}
		return roleStr;
	}

	public void setRoleStr(String roleStr) {
		this.roleStr = roleStr;
	}

	public List<TreeBean> getMenuList() {
		return menuList;
	}

	public void setMenuList(List<TreeBean> menuList) {
		this.menuList = menuList;
	}
	
}